package com.AbstractTemplate;

import java.util.Scanner;

/**
 * ClassName: BusinessTest
 * Package:
 * Description:
 *
 * @Author 软件232班——欧阳昊淼
 * @Create 2024/9/9 15:17
 * @Version 17.0.2
 */
public class BusinessTest {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        Military s1 = new Military();
        double sum = 1000;
        System.out.println("欢迎来到银行大厅：");
        System.out.println("1.挂号排队");
        System.out.println("2.办理具体业务：取款或理财");
        System.out.println("3.取款");
        System.out.println("4.理财");
        System.out.println("5.反馈评价");
        System.out.println("6.退出系统");
        System.out.println("----------------------");
while (true){
    System.out.println("请点击选择：");
    switch (sc.nextInt()){
        case 1:
            System.out.println(s1.takeNumber() + "排队成功，正在办理业务！");
            break;
        case 2:
            System.out.println(s1.transact() + "办理业务成功！");
            break;
        case 3:
            sum -= 1;
            System.out.println("取了多少钱：" + sum + "￥");
            break;
        case 4:
            sum += 1;
            System.out.println("存了多少钱：" + sum + "￥");
            break;
        case 5:
            System.out.println(s1.evaluate() + "服务满意，☆(≧▽≦)☆");
            break;
        case 6:
            System.exit(0);
            return;
        default:
            System.out.println("输入有误");
            }
         sc.next();

        }
    }
}
